package Homework;

import java.util.List;

public class MyTest {
    public static void main(String[] args) {
        IUse use =new UseImp();
        use.add(new Commodity(5,"纸巾","39","纸巾厂","2021-03-28"));

        System.out.println(use.show());
        System.out.println(use.codeSearch(2));

        System.out.println(use.delete(0));

        System.out.println("-------------");
        System.out.println(use.vSearch("球"));
        System.out.println("--------------");

        use.rank("日期");
        List<Commodity> li = use.show();
        for (Commodity c:li){
            System.out.println(c);
        }


    }
}
